package com.blueocean_health.care.management.mapper;

import com.blueocean_health.care.management.domain.base.Team;
import com.blueocean_health.care.management.domain.dto.PullDownDto;
import com.blueocean_health.care.management.domain.dto.TeamPayDto;
import com.blueocean_health.care.management.util.MyMapper;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

public interface TeamMapper extends MyMapper<Team> {

    @Select("SELECT  team_id,team_name,team_phone,team_staff_phone,team_depict,team_pic,count_method  FROM team WHERE is_active = 1  AND team_id =  #{teamId}")
    Team getTeamById(String teamId);

    /**
     * 项目下拉列表
    * @Title: getAllProjectByFirstOrg
    * @param firstOrg
    * @version V1.0.8
     */
	List<PullDownDto> getAllProjectByFirstOrg(@Param("firstOrg")String firstOrg);
	
	@Update("update team set worker_pay_pattern=#{workerPayPattern},worker_pay_proportion=#{workerPayProportion} where team_id =#{teamId}")
	Boolean changeHosipital(TeamPayDto teamPayDto);
     
	
	
}